#!/usr/bin/perl
# removes all provider-sent spam
use strict;
use warnings;

my ($x);  # placeholders

while (<>) {
$x = $_;
# reformat the date string to be mysqlish
	if ($x =~ m/^Insert into Inbox values \('','Inbox','[[:digit:]:\s-]*','([^',]*)',/) {
		if ("$1" ~~ m/\+?[[:digit:]]{11,12}/) {
			print "$x";
		}
	} else {
		print "$x";
	}
}
